package com.ww.yaodao.util;

import com.alipay.service.schema.util.StringUtil;

import javax.servlet.http.HttpServletRequest;

/**
 * @Author wanziyan
 * @Date 2023-04-11:24
 */
public class UserUtils {
    // 得到token
    public static String getParamToken(HttpServletRequest request){
        String accessTokenInRequest = request.getParameter("Authorization");
        if(StringUtil.isEmpty(accessTokenInRequest)) {
            accessTokenInRequest = request.getHeader("Authorization");
        }
        return accessTokenInRequest;
    }

}
